package com.hcx.base.thread.pool;

import java.util.concurrent.RejectedExecutionHandler;
import java.util.concurrent.ThreadPoolExecutor;

/**
 * @author huangchengxiao
 * @date 2024/3/27 12:45
 */
public class MyRejectedExecutionHandler implements RejectedExecutionHandler {
    @Override
    public void rejectedExecution(Runnable r, ThreadPoolExecutor executor) {
        //这是自定义的相关拒绝策略
        System.out.println("我进行了拒绝策略");
    }
}
